home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Mobiclic 72
/
MOBICLIC 72.ISO
/
mac
/
DATA
/
TCHATCHE
/
doggy2004.cst
/
00426_Script_426
< prev
next >
Wrap
Text File
|
2005-02-02
|
2KB
|
75 lines
-- gestion des rolls sur les boutons
property s, nom
global laboActif,laboOK,laboH,laboV,pisteLabo,sonIntLangues,dernierSon
global interLangues
on beginSprite me
s = me.SpriteNum
nom = sprite(s).member.name
if nom contains "Micro" then
pisteLabo = s
sprite(s).member = member("Micro2")
end if
if voidP(interlangues) then interfaceOn
end
on MouseEnter me
-- conditions d'annulation du script ----------------------------
if _movie.pauseState() then exit
if interLangues=0 then exit
if laboActif=1 then exit
if sprite(s).member = member("Micro2") then exit
_player.cursor(280)
sprite(s).member = nom & "_" & suffixeLangue() & "_1"
-- jouer le son correspondant au bouton si aucun son ne se joue
if sound(3).status = 3 then exit
if sonIntLangues = 0 then exit
LBout = ["Voc0","JeuVoc0","Dialog0","Jeu0","Son0","Micro0"]
p = getPos(LBout,nom)
if p<>0 then
nomSon = "bout" & string(p)
memSon = dernierSon
sound(4).volume = sound(3).volume
sound playFile(4, "@/sons_tchatche:" & nomSon & suffixeLangue())
dernierSon = memSon
end if
end
on mouseLeave me
-- conditions d'annulation du script ----------------------------
if _movie.pauseState() then exit
if interLangues=0 then exit
if laboActif=1 then exit
if sprite(s).member = member("Micro2") then exit
_player.cursor(-1)
sound(4).stop()
sprite(s).member = nom & "_" & suffixeLangue()
end
on mouseUp me
-- conditions d'annulation du script ----------------------------
if laboActif=1 then exit
if interLangues=0 then exit
if sprite(s).member = member("Micro2") then exit
if sound(3).status = 3 and sprite(s).member.name contains "micro" then exit
if _mouse.mouseV<455 then exit
-- actions valides ----------------------------------------------
boutonClic = nom.char[1..4]
case boutonClic of
"Voc0" : acces "tcha01"
"JeuV" : acces "tcha03"
"Dial" : acces "tcha02"
"Jeu0" : acces "tcha04"
"Micr" : -- gestion du micro
if laboOK = 1 then
sprite(pisteLabo).member = nom & "_" & suffixeLangue()
laboActif=1
_player.cursor(-1)
paletteLabo
end if
end case
end